<form id="edit-form" role="form" data-toggle="validator" method="POST" action="<?= Tools::siteurl("page/edit/ids/{$row['id']}") ?>">
    <div class="row">
        <div class="col-xs-12 col-sm-6">
            <div class="form-group">
                <label for="title" class="control-label">标题:</label>
                <input type="text" class="form-control" id="title" name="row[title]" value="<?= $row['title'] ?>" required="required" />
            </div>
            <div class="form-group">
                <label for="subtitle" class="control-label">子标题:</label>
                <input type="text" class="form-control" id="subtitle" name="row[subtitle]" value="<?= $row['subtitle'] ?>" />
            </div>
            <div class="form-group">
                <label for="diyname" class="control-label">Diyname:</label>
                <input type="text" class="form-control" id="diyname" name="row[diyname]" value="<?= $row['diyname'] ?>" required="required" />
            </div>
            <div class="form-group">
                <label for="tplname" class="control-label">模板:</label>
                <input type="text" class="form-control" id="pagetpl" name="row[tplname]" value="<?= $row['tplname'] ?>" />
            </div>
            <div class="form-group">
                <label for="keywords" class="control-label">关键字:</label>
                <input type="text" class="form-control" id="keywords" name="row[keywords]" value="<?= $row['keywords'] ?>" />
            </div>
            <div class="form-group">
                <label for="description" class="control-label">描述:</label>
                <textarea name="row[description]" id="description" class="form-control" cols="30" rows="3"><?= $row['description'] ?></textarea>
            </div>
            <div class="row">
                <div class="col-sm-4">
                    <div class="form-group form-inline">
                        <label for="weigh" class="control-label">权重:</label>
                        <input type="text" class="form-control" id="weigh" name="row[weigh]" value="<?= $row['weigh'] ?>" required="required" size="6" />
                    </div>
                </div>
                <div class="col-sm-4">
                    <div class="form-group form-inline">
                        <label for="hits" class="control-label">浏览:</label>
                        <input type="text" class="form-control" id="hits" name="row[hits]" value="<?= $row['hits'] ?>" required="required" size="6" />
                    </div>
                </div>
                <div class="col-sm-4">
                    <div class="form-group form-inline">
                        <label for="comments" class="control-label">评论:</label>
                        <input type="text" class="form-control" id="comments" name="row[comments]" value="<?= $row['comments'] ?>" required="required" size="6" />
                    </div>
                </div>
            </div>
        </div>
        <div class="col-xs-12 col-sm-6">

            <div class="form-group">
                <label for="category_id" class="control-label">类别:</label>
                <select name="row[category_id]" class="form-control selectpicker" required="required">
                    <?= $categoryoptions; ?>
                </select>
            </div>
            <div class="form-group">
                <label for="flag" class="control-label">属性:</label>
                <select name="row[flag][]" multiple="multiple" class="form-control multiselect multiselect-primary selectpicker">
                    <?= $flagoptions; ?>
                </select>
            </div>
            <div class="form-group">
                <label for="publishtime" class="control-label">发布时间:</label>
                <input type="text" class="form-control datetimepicker" id="publishtime" name="row[publishtime]" value="<?= date("Y-m-d H:i:s", $row['publishtime']) ?>" required="required" />
            </div>
            <div class="form-group">
                <label for="createtime" class="control-label">添加时间:</label>
                <input type="text" class="form-control datetimepicker" id="createtime" name="row[createtime]" value="<?= date("Y-m-d H:i:s", $row['createtime']) ?>" required="required" />
            </div>
        </div>
        <div class="col-xs-12">
            <textarea name="row[content]" id="content" class="summernote" cols="30" rows="5">
                <?= $row['content'] ?>
            </textarea>
        </div>
    </div>
</div>
<div class="form-group">
    <label for="content" class="control-label">状态:</label>
    <input type="radio" name="row[status]" value="normal" id="status-normal" <?= $row['status'] == 'normal' ? 'checked' : '' ?> />
    <label for="status-normal">正常</label>
    <input type="radio" name="row[status]" value="hidden" id="status-hidden" <?= $row['status'] == 'hidden' ? 'checked' : '' ?> />
    <label for="status-hidden">隐藏</label>
</div>
</form>